Skip to content

[*] remove fmt.Println from webserver tests#1218

Merged
pashagolub merged 2 commits intocybertec-postgresql:masterfrom
Makeepan-dev:refactor/standardize-logging
Feb 24, 2026
Merged

[*] remove fmt.Println from webserver tests#1218
pashagolub merged 2 commits intocybertec-postgresql:masterfrom
Makeepan-dev:refactor/standardize-logging

Conversation

@Makeepan-dev
Copy link
Contributor

Description

While reviewing the test suite, I noticed fmt.Println being used in internal/webserver/server_test.go. This pollutes the standard console output during test runs.

This PR replaces those instances with t.Log(), ensuring that test logs are only printed when a test fails or when the test suite is explicitly run with the verbose flag (-v).

Changes Made

  • Replaced fmt.Println with t.Log in server_test.go to conform to standard Go testing practices and keep CI logs clean.

@pashagolub pashagolub changed the title test: replace fmt.Println with t.Log in webserver tests [*] replace fmt.Println with t.Log in webserver tests Feb 22, 2026
@pashagolub pashagolub self-assigned this Feb 22, 2026
@pashagolub pashagolub added the test New test case or request label Feb 22, 2026
@pashagolub
Copy link
Collaborator

Thanks. Please fix the issues

@pashagolub pashagolub force-pushed the refactor/standardize-logging branch from 19ce039 to 8723452 Compare February 24, 2026 16:22
@pashagolub pashagolub changed the title [*] replace fmt.Println with t.Log in webserver tests [*] remove fmt.Println from webserver tests Feb 24, 2026
@pashagolub pashagolub merged commit b737955 into cybertec-postgresql:master Feb 24, 2026
Makeepan-dev added a commit to Makeepan-dev/pgwatch that referenced this pull request Feb 25, 2026
…1218)

* test: replace fmt.Println with t.Log in webserver tests

* fix tests

---------

Co-authored-by: Pavlo Golub <pavlo.golub@gmail.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

test New test case or request

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants